#include <iostream>
#include <string>

#include "OGSADAIConnection.h"

int main()
{
	std::cout << "hello testConnection" << std::endl;
	
	OGSADAIConnection* conn = OGSADAIConnection::GetConnection();
	
	std::cout << "connect: " << conn->open("http://localhost:8080/wsrf/services/ogsadai/DataService", "MySQLResource", "tom", "pass") << std::endl;

	std::cout << "executeQuery: " << conn->executeQuery("SELECT * from USER where id < '10'") << std::endl;
	
	std::cout << "close: " << conn->close() << std::endl;
	
	delete conn;
	
	std::cout << "bye" << std::endl;
	
	return 0;
}
